QA Wizard Pro can perform mouse action statements, such as Click and Mouse Move, on HTML tables, cells, and controls in cells.
When you add a statement to an HTML table, you identify search criteria to help QA Wizard Pro locate the control to perform the action on it during playback. The search criteria is identified in the GetControlFromTable statement, which is used in place of the control name in statements.
Note: You may need to use multiple GetControlFromTable statements to add mouse and keyboard action statements to nested HTML tables. See Testing nested HTML tables.
1. Select the script line above where to add the statement.
2. Choose Script > Add Statement.
The Add Statement dialog box opens.
3. Select a statement in the Mouse Actions category.
4. The Application/version field is automatically set with the context. This information is used to populate the Window and Control fields on the Add Statement dialog box with values from the application repository.
If QA Wizard Pro cannot identify the context, None is selected. This usually occurs when you add statements to a utility script that is only called by other scripts because the context is set in the script that calls it. If an application/version is required, select it from the list.
5. Select the Window that includes the table.
A screenshot of the selected window is displayed.
6. Select the table as the Control.
The selected table is outlined with a red box in the screenshot.
7. Click Table Data to select the control search criteria.
The Child Control Search Criteria dialog box opens.
8. Enter the Row Index and Column Index to search.
You can use integers, script variables, or the ANYROW and ANYCOLUMN constant variables, which search all rows and columns in the table. The index of the first table row and column is 1.
Note: If the table is dynamic, use the GetColumnFromRowIndex or GetRowFromColumnIndex statements to find the row index or column index during playback. See Finding HTML table row and column index values.
9. Select the Control Type to search for.
The HTMLElement control type can be used to search for table cells or other HTML elements, such as <div> tags, that are not recognized as controls.
10. Select a Property, Action, and Expected Value to use to identify the control.
A control must be unique for QA Wizard Pro to differentiate it from other controls in the table. Select at least one property if the table includes more than one instance of the selected control type.
Tip: Selecting the Tag ID property generally helps refine the search for the control.
11. Select any additional properties to perform a more specific search.
12. Click OK.
A summary of the search criteria is displayed in the Child Control Search Criteria field.
13. Select Context Menu Item to perform the action on a context menu item. See Testing context menus.
14. Enter or select any additional statement information.
15. Click OK to add the statement to the script.